package com.baiwei.vpnapi.utils;

import com.baiwei.vpnapi.entity.VpnUser;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ScopedProxyMode;
import org.springframework.stereotype.Component;
import org.springframework.web.context.annotation.RequestScope;

/**
 * @program: vpnapi
 * @description: 请求作用域bean
 * @author: Mr. Stone
 * @create: 2020-03-05 20:23
 **/
@Component
@RequestScope(proxyMode = ScopedProxyMode.TARGET_CLASS)
public class RequestScopeBean {
    private VpnUser currentUser;

    public String getToken() {
        return token;
    }

    public void setToken(String token) {
        this.token = token;
    }

    private String token;

    public VpnUser getCurrentUser() {
        return currentUser;
    }

    public void setCurrentUser(VpnUser currentUser) {
        this.currentUser = currentUser;
    }
}
